//公司接口相关的函数
import request from "../../utils/request"


//公司列表
export const companies = (params) => {
    return request.get("/api/companies/index", { params })
}
//注册公司
export const storeCompanyAndUser = (data) => {
    return request.post("/api/companies/store", (data))
}
//审核公司
export const Companyreview = (data) => {
    return request.post("/api/companies/review", (data))
}
//添加部门
export const departments = (data) => {
    return request.post("/api/departments/store", (data))
}
//编辑部门
export const Editdepartments = (data) => {
    return request.post("/api/departments/update", (data))
}
//软删除部门
export const deldepartments = (data) => {
    return request.post("/api/departments/destroy", data)
}
//部门列表
export const departmentsList = (params) => {
    return request.get("/api/departments/index", { params })
}
//新建项目
export const Projects = (data) => {
    return request.post("/api/projects/store", (data))
}
//查询单个公司
export const Getcompanies = (params) => {
    return request.get("/api/companies/show", { params })
}
//查询单个部门
export const Getdepartments = (params) => {
    return request.get("/api/departments/show", { params })
}
//编辑公司
export const modifycompanies = (data) => {
    return request.post("/api/companies/update", (data))
}
//公司回收站
export const Companiesrecycle = (params) => {
    return request.get("/api/companies/recycle", { params })
}
//公司回收站恢复
export const companiesretrieve = (data) => {
    return request.post("/api/companies/retrieve", { data })
}
//公司回收站永久删除
export const companiesdelete = (data) => {
    return request.post("/api/companies/delete", data)
}
//用户导入
export const Import = (data) => {
    return request.post("/api/organized/user_import", (data))
}
//获取公司下的部门
export const companiesDepart = (params) => {
    return request.get("/api/companies/departments", { params })
}
//获取部门下的员工
export const departmentsUser = (params) => {
    return request.get("/api/departments/users", { params })
}
//获取审批类型
export const getType = (data) => {
    return request.get("api/approval/get_type", (data))
}
/* export const Import = (params) => {
    return request.get("/api/companies/company_id", {params})
} */
